bitkeeper revision 1.1760.1.5 (42c105a0IGE_9KbvmOfox8TMahmQVw)
authorkaf24@firebug.cl.cam.ac.uk <kaf24@firebug.cl.cam.ac.uk>
Tue, 28 Jun 2005 08:09:04 +0000 (08:09 +0000)
committerkaf24@firebug.cl.cam.ac.uk <kaf24@firebug.cl.cam.ac.uk>
Tue, 28 Jun 2005 08:09:04 +0000 (08:09 +0000)
Only enable PGE in CR4 if the CPU supports the feature.
Signed-off-by: Keir Fraser <keir@xensource.com>
xen/arch/x86/setup.c
xen/arch/x86/x86_32/mm.c

index 53690b8dbe5e8e9d5ff3ab6e493cab5df7b5c004..1fb131b2c866dc12a2af2e4b7eeffabd0ac00a35 100644 (file)
@@ -87,7 +87,7 @@ struct cpuinfo_x86 boot_cpu_data = { 0, 0, 0, 0, -1, 1, 0, 0, -1 };
 #if CONFIG_PAGING_LEVELS > 2
 unsigned long mmu_cr4_features = X86_CR4_PSE | X86_CR4_PGE | X86_CR4_PAE;
 #else
-unsigned long mmu_cr4_features = X86_CR4_PSE | X86_CR4_PGE;
+unsigned long mmu_cr4_features = X86_CR4_PSE;
 #endif
 EXPORT_SYMBOL(mmu_cr4_features);
 
index b388c1cc4980c08136d42b5b9494911dccad8c14..691db03bdb83e72c679e61706d712302fa2f5735 100644 (file)
@@ -80,6 +80,7 @@ void __init paging_init(void)
     if ( cpu_has_pge )
     {
         /* Suitable Xen mapping can be GLOBAL. */
+        set_in_cr4(X86_CR4_PGE);
         PAGE_HYPERVISOR         |= _PAGE_GLOBAL;
         PAGE_HYPERVISOR_NOCACHE |= _PAGE_GLOBAL;
         /* Transform early mappings (e.g., the frametable). */